import { createNamespacedHelpers } from 'vuex'
export function registerState (moduleName, states = []) {
  const { mapState } = createNamespacedHelpers(moduleName)
  return {
    ...mapState(states)
  }
}
export function registerActions (moduleName, actions = []) {
  const { mapActions } = createNamespacedHelpers(moduleName)
  return {
    ...mapActions(actions)
  }
}
